跟c語言的switch很像,不用寫break
package main
import "fmt"
func checkValue(s int) {
	switch s {
	case 0:
	case 1:
		fmt.Println("check value is ", s)
	}
}
func main() {
	checkValue(0)
	checkValue(1)
}
期望是
// check value is 0
// check value is 1
但結果只輸出一行
// check value is 1
package main
import "fmt"
func checkValue(s int) {
	switch s {
	case 0:
		fallthrough
	case 1:
		fmt.Println("check value is ", s)
	}
}
func main() {
	checkValue(0)
	checkValue(1)
}
package main
import "fmt"
func checkValue(s int) {
	switch s {
	case 0, 1:
		fmt.Println("check value is ", s)
	}
}
func main() {
	checkValue(0)
	checkValue(1)
}
如果判斷式是一種情況
if (condition) {
} else {
}
改寫
if (condition) {
  return ...
} return ...
若多個判斷情況
需動用else if 兩次以上
建議直接用switch case